package Test04;

/**
 * @Author: Re
 * @Date: 2020/12/1 0:29
 */
public class Test {
    public static void main(String[] args) {
        Rectangle rect1=new Rectangle(10,10);
        Rectangle rect2=new Rectangle(5,10);
        rect1.compare(rect2);
        System.out.println("rect1 area is "+rect1.area());
        System.out.println("rect2 area is "+rect2.area());
        System.out.println("rect1 perimeter is "+rect1.perimeter());
        System.out.println("rect2 perimeter is "+rect2.perimeter());
       if(rect1.isSquare()){
           System.out.println("rect1 is Square");
       }else {
           System.out.println("rect1 is not Square");
       }
       if(rect2.isSquare()){
           System.out.println("rect2 is Square");
       }else {
           System.out.println("rect2 is not Square");
       }
    }
}
